<template>
    <div>
        <div class="title">
            <img :src="title.list_pic_url" alt="" class="title-img">
            <p class="title-name">{{title.name}}</p>
            <p class="title-desc">{{title.simple_desc}}</p>
        </div>
        <van-grid clickable :column-num="2" v-for="item in list" :key="item.id" class="brand-list">
            <van-grid-item class="brand-item">
                <img :src="item.list_pic_url" alt="" class="brand-img">
                <p class="brand-name">{{item.name}}</p>
                <p class="brand-price">{{item.retail_price}}起</p>
            </van-grid-item>
          </van-grid>
    </div>
</template>

<script>
import {brandDetail} from "@/axios/index"
export default {
    name: 'brandDetai',
    data() {
        return {
            title:{},
            list:[]
        };
    },
    
    async mounted() {
        // 拿到制造商id
        let id=this.$route.params.id;
        // console.log(this.$route.params.id);
        let res=await brandDetail({'id':id})
        this.title=res.data;
        this.list=res.goodsList;
        console.log(res);
    },

    methods: {
        
    },
};
</script>

<style scoped lang="scss">
.title{
    .title-img{
        width: 750px;
        height: 326px;
    } 
}
.brand-list{

}
.brand-img{
    width: 300px;
    height: 200px;
}

</style>